#ifndef CHART_H
#define CHART_H

#include <QWidget>
#include <QPainter>
#include <QChart>
#include <QtCharts>

#include <QDateTime>
#include <QTime>
#include <QTimer>



namespace Ui {
class chart;
}

class chart : public QWidget
{
    Q_OBJECT
public:
    explicit chart(QWidget *parent = nullptr);
    ~chart();

signals:
    void back();

private slots:
    void on_back_button_clicked();
    void InitChart();
    void Timer_task1_now_pain();
    void Paint_cansu_now();
    void Paint_cansu_now_Proc(const QVector<QString>& datetimes, const QVector<int>& temperatures);

    void Paint_cansu_past_Proc(const QVector<QString>& datetimes, const QVector<int>& temperatures);

    void on_pushButton_2_clicked();

    void on_pushButton_3_clicked();
    void back_set_color();

//    void on_pushButton_clicked();

private:
    Ui::chart *ui;
    QTimer     *timer_paint_now;
};

#endif // CHART_H
